/** When your routing table is too long, you can split it into small modules **/

import Layout from '@/layout'

const adminRouter = {
  path: '/admin',
  component: Layout,
  redirect: 'noRedirect',
  name: 'AdminManager',
  meta: {
    title: '用户管理',
    icon: 'user',
    roles: ['ROLE_UserList_Show', 'ROLE_UserPerm_Show']
  },
  children: [
    {
      path: 'adminlist',
      component: () => import('@/views/admin'),
      name: 'AdminList',
      meta: { title: '用户列表', roles: ['ROLE_UserList_Show'], noCache: true }
    },
    {
      path: 'rolelist',
      component: () => import('@/views/role'),
      name: 'RoleList',
      meta: { title: '权限管理', roles: ['ROLE_UserPerm_Show'] }
    }
  ]
}

export default adminRouter
